<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript">
        //定义无参函数(方法)
        function  fun(){
            alert("无参函数被调用");
        }
        fun();

        //定义代参函数(方法)
        function  fun1(a, b){
            alert("带参函数被调用a=" + a + "b=" + b);
        }
        fun1(10,"qwrqw");

        //函数方法的return 返回值
        function  fun2(a,b){
            var sum = a+b;
            return sum;
        }
        alert("函数方法的return=" + fun2(100, 500));
    </script>
</head>
<body>

</body>
</html>